﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using EzDesk.MVVMBase;

using Microsoft.Practices.Unity;
using Microsoft.Practices.Unity.Utility;
using EzDesk.Generic;
using EzDesk.DesktopClient.ViewModel;

namespace EzDesk.DesktopClient
{
    public partial class IMClient
    {
        public static IMClient CurrentClient
        {
            get
            {
                return IMClient.Current as IMClient;
            }
        }

        public Window MainView
        {
            get;
            set;
        }

        public UnityContainer Container
        {
            get
            {
                return GenericDictionary<UnityContainer>.Instance;
            }
        }

        public Window NotificationView
        {
            get;
            set;
        }

        private Window _functionPageView;

        public Window FunctionPageView
        {
            get
            {
                if (null == _functionPageView)
                {
                    FunctionPageViewModel viewModel = new FunctionPageViewModel();
                    _functionPageView = viewModel.View as Window;
                }
                return _functionPageView;
            }
            set
            {
                _functionPageView = value;
            }
        }

        public UserManagement UserManagement
        {
            get;
            set;
        }
        public DataManagement DataManagement
        {
            get;
            set;
        }
        public UpdateDataManagement UpdateDataManagement { get; set; }
        public ServiceConfigurationManagement ServiceConfigurationManagement { get; set; }
    }
}
